home *** CD-ROM | disk | FTP | other *** search
- // Copyright (C) 1997-2002 Alias|Wavefront,
- // a division of Silicon Graphics Limited.
- //
- // The information in this file is provided for the exclusive use of the
- // licensees of Alias|Wavefront. Such users have the right to use, modify,
- // and incorporate this code into other products for purposes authorized
- // by the Alias|Wavefront license agreement, without fee.
- //
- // ALIAS|WAVEFRONT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
- // INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
- // EVENT SHALL ALIAS|WAVEFRONT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
- // CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
- // DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
- // TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- // PERFORMANCE OF THIS SOFTWARE.
- //
- // Copyright (C) 1997-2000 Alias|Wavefront,
- // a division of Silicon Graphics Limited.
- //
- // The information in this file is provided for the exclusive use of the
- // licensees of Alias|Wavefront. Such users have the right to use, modify,
- // and incorporate this code into other products for purposes authorized
- // by the Alias|Wavefront license agreement, without fee.
- //
- // ALIAS|WAVEFRONT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
- // INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
- // EVENT SHALL ALIAS|WAVEFRONT BE LIABLE FOR ANY SPECIAL, INDIRECT OR
- // CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
- // DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
- // TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- // PERFORMANCE OF THIS SOFTWARE.
- //
- //
- // Alias|Wavefront Script File
- //
- // Creation Date: March 24, 1999
- //
- //
- // Procedure Name:
- // AErevolveTemplate
- //
- // Description Name;
- // Creates the attribute editor controls for the subdivToPoly node
- //
- // Input Value:
- // nodeName
- //
- // Output Value:
- // None
- //
-
- global proc subdivFormatControls( string $nodeName )
- {
- string $formatAttrName = $nodeName + ".format";
- int $value = `getAttr $formatAttrName`;
-
- switch ($value) {
-
- case 0:
- // Uniform or constant depth
- editorTemplate -dimControl $nodeName "depth" false;
- editorTemplate -dimControl $nodeName "sampleCount" false;
- editorTemplate -dimControl $nodeName "maxPolys" true;
- editorTemplate -dimControl $nodeName "extractPointPosition" false;
- break;
-
- case 1:
- // Adaptive or leaf
- editorTemplate -dimControl $nodeName "depth" true;
- editorTemplate -dimControl $nodeName "sampleCount" false;
- editorTemplate -dimControl $nodeName "maxPolys" true;
- editorTemplate -dimControl $nodeName "extractPointPosition" true;
- break;
-
- case 2:
- // Max Number of Polygons
- editorTemplate -dimControl $nodeName "depth" true;
- editorTemplate -dimControl $nodeName "sampleCount" true;
- editorTemplate -dimControl $nodeName "maxPolys" false;
- editorTemplate -dimControl $nodeName "extractPointPosition" true;
- break;
-
- case 3:
- // Vertices
- editorTemplate -dimControl $nodeName "depth" false;
- editorTemplate -dimControl $nodeName "sampleCount" true;
- editorTemplate -dimControl $nodeName "maxPolys" true;
- editorTemplate -dimControl $nodeName "extractPointPosition" true;
- break;
-
- }
- }
-
- global proc AEsubdivToPolyTemplate( string $nodeName )
- {
-
- editorTemplate -beginScrollLayout;
-
- editorTemplate -beginLayout "Subdiv Tessellate History" -collapse false;
-
- editorTemplate -callCustom "AEinputNew \"Input Subdiv Surface\""
- "AEinputReplace \"Input Subdiv Surface\""
- "inSubdiv";
-
- editorTemplate -beginLayout "Options";
- editorTemplate -addControl "format" "subdivFormatControls";
- editorTemplate -addControl "depth";
- editorTemplate -addControl "sampleCount";
- editorTemplate -addControl "maxPolys";
- editorTemplate -addControl "extractPointPosition";
- editorTemplate -addControl "shareUVs";
- editorTemplate -endLayout;
-
- editorTemplate -endLayout;
-
- // include/call base class/node attributes
- AEabstractBaseCreateTemplate $nodeName;
-
- //suppressed attributes
- editorTemplate -suppress "inSubdiv";
- editorTemplate -suppress "outMesh";
- editorTemplate -suppress "inSubdCVId";
- editorTemplate -suppress "outv";
- editorTemplate -suppress "outSubdCVId";
- editorTemplate -suppress "applyMatrixToResult";
- editorTemplate -suppress "subdNormals";
-
- editorTemplate -addExtraControls;
- editorTemplate -endScrollLayout;
- }
-
-